protocol negotiation